using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;

public partial class WebMaster_UserControls_ucLogout : System.Web.UI.UserControl
{
    protected string manager = "";
    protected void Page_Load(object sender, EventArgs e)
    {
        if (Session["UserLogin"] != null)
            lblUserLogin.Text = Session["UserLogin"].ToString();
        if (Session["UserRole"] != null)
        {
            GssBL.BLLogon.UserRole enumRole = (GssBL.BLLogon.UserRole)Session["UserRole"];
            if (enumRole == GssBL.BLLogon.UserRole.WebMaster)
                manager = "<td class=\"logout\"><a href=\"Management.aspx\">User Management</a></td><td class=\"logout\">|</td>";
        }
    }
    protected void lkbLogout_Click(object sender, EventArgs e)
    {
        Session.Abandon();
        Session.RemoveAll();
        Response.Redirect("WebMasterLogin.aspx", false);
    }
    protected void lkbChangePass_Click(object sender, EventArgs e)
    {
        string idLogon = "";
        if (Session["IDLogon"] != null)
            idLogon = Session["IDLogon"].ToString();
        Response.Redirect(GlobalClassBE.PageName.ManagementChange + "?id=" + idLogon, false);
    }
    protected void lkbProfile_Click(object sender, EventArgs e)
    {
        string idLogon = "";
        if (Session["IDLogon"] != null)
            idLogon = Session["IDLogon"].ToString();
        Response.Redirect(GlobalClassBE.PageName.ManagementProfile + "?id=" + idLogon, false);
    }
}
